import Cookies from 'js-cookie'

const TokenKey = 'token_key'

export function getToken () {
  return Cookies.get(TokenKey)
}

export function setToken (token, id) {
  Cookies.set('id', id)
  return Cookies.set(TokenKey, token)
}

export function removeToken () {
  Cookies.remove('id')
  return Cookies.remove(TokenKey)
}

export function getId () {
  return Cookies.get('id')
}
